package chapter13;

import java.util.ArrayList;
import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * Description:
 *
 * @author lzy
 * @create 2018-03-23 下午3:45
 */
public class BookListTest {
    public static void main(String[] args) {
        List<Book> books = new ArrayList<>();
        books.add(new Book("test1", 12.3));
        books.add(new Book("test2", 22.3));
        books.add(new Book("test3", 32.3));
        books.add(new Book("test4", 42.3));
        books.forEach(System.out::println);

        System.out.println("----- after remove ----");
        books.remove(new Book("test2", 22.3));
        books.forEach(System.out::println);
    }
}
